#include<iostream>
using namespace std;
int fun(char s, int x)
{
	int ct = 1;
	while (x--)
		ct *= 26;
	return (s - 64) * ct;
}
int main()
{
	int m = 0;
	char s1[100] = { 0 };
	cin >> m;
	int x=0;
	int ct = 0;
	if (m < 27)
	{
		s1[x] = m % 27 + 64;
		x++;
	}
	else if (m % 26 == 0)
	{
		while (m>27 )
		{
			s1[x] = m % 27+1 + 64;
			x++;
			m /= 26;
		}
		s1[x] = m % 27 -1+ 64;
		x++;
	}
	else
	{
		while (m)
		{

			s1[x] = m % 26 + 64;

			m /= 26;
			x++;

		}
	}
	int j = x;

	while (j--)
		cout << s1[j];
}